<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>元素显示模式的转换</title>
    <style>
        a {
            width: 350px;
            height: 250px;
            background-color: aqua;
            /* 把行内元素转换为块级元素 */
            display: block;
            text-decoration: none;
        }
        div {
            width: 300px;
            height: 100px;
            background-color: chocolate;
            display: inline;
        }
        span {
            width: 300px;
            height: 200px;
            background-color:hotpink;
            display: inline-block;
        }

    </style>

</head>

<body>
    <a href="#">元素显示模式的转换示例：此为空连接 <br>
        实现方法：<br>
        <img src="img/行转块.png" alt="元素显示模式的转换示例">
    </a>
    <div>块级元素转为行内元素示例</div>
    <div><img src="img/块转行.png" alt="元素显示模式的转换示例"></div>
    <span>行内元素转为行内块元素</span>
    <span>
        <img src="img/行转行内块.png" alt="元素显示模式的转换示例"></span>
</body>

</html>